package com.project.bean;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.util.List;

/**
 * 房间实体类
 */
@TableName("t_room")
public class RoomBean {
    //房间id
    @TableId(value = "pk_roomId",type = IdType.AUTO)
    private Integer id;
    //房间地址
    @TableField("t_roomName")
    private String roomName;
    //房间类型
    @TableField("t_roomSex")
    private String roomSex;
    //房间最大人数
    @TableField("t_roomMaxNumber")
    private Integer roomMaxNumber;
    // 房间以住人数
    @TableField(exist = false)
    private Integer roomNumbers;
    //房间状态
    @TableField("t_roomState")
    private String roomState = "正常";
    //房间学生集合
    @TableField(exist = false)
    private List<StudentBean> studentList ;
    public RoomBean (){}

    public RoomBean(String roomName, String roomSex, Integer roomMaxNumber) {
        this.roomName = roomName;
        this.roomSex = roomSex;
        this.roomMaxNumber = roomMaxNumber;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getRoomName() {
        return roomName;
    }

    public void setRoomName(String roomName) {
        this.roomName = roomName;
    }

    public String getRoomSex() {
        return roomSex;
    }

    public void setRoomSex(String roomSex) {
        this.roomSex = roomSex;
    }

    public Integer getRoomMaxNumber() {
        return roomMaxNumber;
    }

    public Integer getRoomNumbers() {
        return roomNumbers;
    }

    public void setRoomNumbers(Integer roomNumbers) {
        this.roomNumbers = roomNumbers;
    }

    public String getRoomState() {
        return roomState;
    }

    public void setRoomState(String roomState) {
        this.roomState = roomState;
    }

    public List<StudentBean> getStudentList() {
        return studentList;
    }

    public void setStudentList(List<StudentBean> studentList) {
        this.studentList = studentList;
    }

    public void setRoomMaxNumber(Integer roomMaxNumber) {
        this.roomMaxNumber = roomMaxNumber;
    }

    @Override
    public String toString() {
        return "RoomBean{" +
                "id=" + id +
                ", roomName='" + roomName + '\'' +
                ", roomSex='" + roomSex + '\'' +
                ", roomMaxNumber='" + roomMaxNumber + '\'' +
                ", roomNumbers='" + roomNumbers + '\'' +
                ", roomState='" + roomState + '\'' +
                ", studentList=" + studentList +
                "}\n";
    }
}
